package view;

import model.Bill;

import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter;

/**
 * @InterfaceName: home
 * @Description:账单功能选择的主页
 * @Author: YourName
 * @Date: 2024/12/24
 */
public class Home {
    public static void login(){
        System.out.println("===========================");
        System.out.println();
        System.out.println("欢迎使用个人账单管理系统");
        System.out.println("===========================");
        System.out.println();
        System.out.println("请选择操作");
        System.out.println("1. 记录收入");
        System.out.println("2. 记录支出");
        System.out.println("3. 查看所有账单");
        System.out.println("4. 查询账单");
        System.out.println("5. 设置月度预算");
        System.out.println("6. 查看月度统计报告");
        System.out.println("7. 退出系统");
        System.out.println("请输入选项序号：");
        System.out.println();
        System.out.println("===========================");
    }
    public static String time() {
        LocalDateTime now = LocalDateTime.now();
        // 使用自定义格式化器将年月日转换为字符串
        DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
        String formattedDate = now.format(formatter);
        return formattedDate; // 输出：yyyy-MM-dd 格式
    }
    public static void viveBill(Bill bill){
        System.out.println(bill.getInputTime());
        System.out.println(bill.getMoney());
        System.out.println(bill.getNotes());
        System.out.println(bill.getType());
    }

}
